package com.example.plane.spirit;

import android.graphics.Bitmap;
import android.graphics.Canvas;
import android.graphics.Matrix;
import android.graphics.Paint;

import com.example.plane.GameActivity;
import com.example.plane.MainActivity;
import com.example.plane.MenuActivity;

import static com.example.plane.MainActivity.*;
import static java.lang.Thread.sleep;

public class Heroplane extends Spirit{

   public Paint p=new Paint();
   public Buttle hpbuttle=new Buttle();
    public Heroplane(){

    }
    public void initView(){
        super.initView(MainActivity.bitmap[1]);
        hpy=GameActivity.Screenheight-hpheight;
        hpx=GameActivity.Scrrenwidth/2-(hpwidth/2);

    }
    public void paint(){

        p.setDither(true);
    }
    public void Draw(Canvas canvas){
        paint();
        super.Draw(canvas);
        buttle(canvas);
    }
   public void logic(){

    }
    public void listen(){

    }
    public void buttle(Canvas canvas){
         hpbuttle.set_buttle_position(hpx,hpy,bitmap);
        hpbuttle.initView();
        hpbuttle.draw(canvas);
         hpbuttle.logic();
        hpbuttle.buttle_remove();
    }
}
